#ifndef INT_TIME_SENSOR_H
#define INT_TIME_SENSOR_H

#include "types.h"
#include "stm32f10x.h"
#include "SensorChannels.h"

// extern void (*ExtIntCallbacks[PHYSENSOR_CHANNELS])(int, int);
// extern void *OpenTimerSensor(int channel, GPIO_TypeDef *Port, uint16_t Pin, uint8_t PortSource, uint8_t PinSource,
// 	void (*ExtIntCallback)(int channel, int IOLevel));
// extern void CloseTimerSensor(void *handle);
// extern int GetTimerSensorIOLevel(void *handle);

extern void (*ExtIntCallbacks[PHYSENSOR_CHANNELS])(int, int);

extern int OpenTimerSensor(int channel, const SensorChannelHw_t *Hw, void (*ExtIntCallback)(int channel, int IOLevel));
extern void CloseTimerSensor(int channel, const SensorChannelHw_t *Hw);
extern int GetTimerSensorIOLevel(int channel);

#endif // ifndef INT_TIME_SENSOR_H
